package com.alvis.media.repository;

import com.alvis.media.domain.User;
import com.alvis.media.domain.VideoInfo;
import com.alvis.media.viewmodel.video.VideoPageRequestVM;
import com.github.pagehelper.PageInfo;
import org.apache.ibatis.annotations.Mapper;
import java.util.List;

@Mapper
public interface VideoInfoMapper extends MediaBaseMapper <VideoInfo>
{

    int deleteByPrimaryKey(Integer videoId);

    int insert(VideoInfo record);

    int insertSelective(VideoInfo record);

    VideoInfo selectByPrimaryKey(Integer videoId);

    int updateByPrimaryKeySelective(VideoInfo record);

    int updateByPrimaryKey(VideoInfo record);
    /**
     * 获取新增视频数量
     * @param filter
     * @return
     */
    int selectNewVideoCount(VideoInfo filter);

    /**
     *get videoId by video url from
     * @param
     * @return
     */
    Integer selectVideoIdByUrl(String videoUrl);



    List <VideoInfo> selectHotVideoList();


    List<VideoInfo> videoPage(VideoPageRequestVM requestVM);
}
